package com.lht.testDemo;

/**
 * @author Eric
 * @version 1.0
 * @date 2019-11-04
 */
public class CodeTest {

    private Integer name;

    public static void main(String[] arg) {

        synchronized (new Object()) {
            System.out.println(demo(99, 100));
        }

    }

    public static int demo(int a, int b) {
        int sum = 0;
        for (int i = 0; i < a; i++) {
            sum += i;
        }
        throw new RuntimeException("error");
    }

    public static void test() {
        int a = 1;
        int b = 2;
        int c = 4;
        int d = 5;
        b = a + b + c + d;
    }

    public void testRef(int a, int b) {
        a = a + b;
    }
}
